package com.tuling.spring;

import com.tuling.mapper.UserMapper;
import com.tuling.spring.factory.MyFactoryBean;
import com.tuling.spring.service.UserService;
import org.springframework.beans.factory.support.AbstractBeanDefinition;
import org.springframework.beans.factory.support.BeanDefinitionBuilder;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

public class SpringApp {
    public static void main(String[] args) {
        AnnotationConfigApplicationContext applicationContext = new AnnotationConfigApplicationContext();
        applicationContext.register(AppConfig.class);
        applicationContext.refresh();
        UserService bean = applicationContext.getBean(UserService.class);
        bean.test();
    }
}
